package _11_整理题目._Spring基础原理._设计模式._02_装饰器模式._穿服装;

public class Shirt extends ClothesDecorator {

    public Shirt(Person person) {
        super(person);
    }

    @Override
    public double cost() {
        return this.person.cost() + 1000;
    }

    @Override
    public void show() {
        this.person.show();
        System.out.println("买了一件衬衫，累计花费 " + this.cost());
    }
}
